<%-- 
    Document   : adminLogin
    Created on : Oct 27, 2011, 4:06:16 PM
    Author     : home
--%>

<%@page import="Admin.Controler.adminLogin"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<script language="javascript">

    function checkInputData()
    {
        if(document.login.email.value == ""){
            alert("You must input Email!");
            document.login.email.focus();
            return false;
        }
        if(document.login.password.value == ""){
            alert("You must input Password!");
            document.login.password.focus();
            return false;
        }
        return true;
    }
</script>

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link rel="stylesheet" type="text/css" media="screen, projection" href="menu.css" />
        <link rel="stylesheet" type="text/css" media="screen, projection" href="style.css" />

        <title>Login Page</title>
    </head>
    <body><div class="wrap1">

            <div class="wrap2">
                <div class="logo" style="height: 110px; padding-top:  0px; "><img src="img/logo.png"/> My sweet home
                    <div class="slogan"> </div>
                </div>
                <div id="menu">
                    <div class="menu">
                        <ul>
                            <li><span class="hlavny_"><a href="index.jsp">Home</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewRealEstate.jsp">Real Estate</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="viewSeller.jsp">User</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewPostHistory.jsp" >Post Histories</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewBank.jsp">Banks</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewDirectory.jsp">Directories</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewFAQs.jsp">FAQ</a></span></li>
                            <li><img src="img/divider2.png" alt="" /></li>
                            <li><span class="hlavny_"><a href="ViewFeedback.jsp">Feedback</a></span></li>
                        </ul>
                    </div>

                    <div  align="center">
                        <br/>
                        <br/>
                        <h1 style="color:orange" >Welcome to Administrator Site </h1>
                        <br/>
                        <br/>
                    </div>
                    <table align="center" width="500" height="200" border="0">
                        <tr>
                            <td align="center">
                                <form name="login" id="login" action="../adminLogin" method="post" onsubmit="return checkInputData()">
                                    <%
                                                Admin.Model.User objUser = new Admin.Model.User();
                                                if (session.getAttribute("loginFail") != null) {
                                                    session.setAttribute("loginFail", null);
                                    %>
                                    <table width="50%" height=30" align="center">
                                        <tr>
                                            <td align="center"> <h3> <p align="center" style="color:#FF0000"> Invalid email or password</p> </h3></td>
                                        </tr>
                                    </table>
                                    <%
                                                }
                                    %>
                                    <table width="250" border="0" bordercolor="#FFFFFF">
                                        <tr>
                                            <td width="80">Email :</td>
                                            <td width="170">
                                                <input name="userEmail" type="text" id="userEmail" /></td>
                                        </tr>
                                        <tr>
                                            <td>Password:</td>
                                            <td>
                                                <input name="userPassword" type="password" id="userPassword" />
                                            </td>
                                        </tr>
                                        <tr>
                                            <td></td>
                                            <td colspan="2" align="center">
                                                <input align="middle" name="btnLogin" type="submit" id="btnLogin" value=" Login" />
                                                <input align="middle" type="reset" name="btnReset" value="Reset"/></td>
                                        </tr>
                                    </table>
                                </form>
                            </td>
                        </tr>
                    </table>
                </div>

                                    <div class="info1" style="height: 80px;">
                                        <div style="display:inline; float:left;">&copy; 2011 <a href="index.jsp">mysweethome.com</a>. Design by <a href="">Group 106 </a>.</div>
                                        <div style="display:inline; float:right;"><a href="http://aptech.vn">Ha Noi - Aptech</a></div>
                                    </div>

            </div>

        </div>

    </body>
</html>
